﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace PHRClient.PatientForms
{
    public partial class History2 : Form
    {
        public History2()
        {
            InitializeComponent();
            
            checkBox1.Checked = true;
            checkBox3.Checked = true;
            checkBox5.Checked = true;

            this.TopLevel = false;
            this.AutoScroll = true;
            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None;
            this.Dock = DockStyle.Fill;
            comboBox1.SelectedItem = "12/08/2014-visit3";
        }

        private void comboBox1_SelectedValueChanged(object sender, EventArgs e)
        {
            //MessageBox.Show(comboBox1.SelectedText+","+comboBox1.SelectedItem+","+comboBox1.SelectedValue);
            if (comboBox1.SelectedItem.Equals("10/08/2014-visit1"))
            {
                
                checkBox1.Checked = true;
                checkBox6.Checked = true;
                checkBox7.Checked = true;
                checkBox4.Checked = true;
                checkBox12.Checked = true;
                checkBox11.Checked = true;
                checkBox14.Checked = true;
                checkBox15.Checked = true;
                checkBox8.Checked = true;
            }
            else if (comboBox1.SelectedItem.Equals("11/08/2014-visit2"))
            {
               
                checkBox1.Checked = false;
                checkBox6.Checked = true;
                checkBox7.Checked = false;
                checkBox4.Checked = true;
                checkBox12.Checked = true;
                checkBox11.Checked = false;
                checkBox14.Checked = true;
                checkBox15.Checked = false;
                checkBox8.Checked = true;
                checkBox13.Checked = true;
            }
            else
            {
               
                checkBox1.Checked = true;
                checkBox6.Checked = true;
                checkBox7.Checked = false;
                checkBox4.Checked = true;
                checkBox12.Checked = false;
                checkBox11.Checked = false;
                checkBox14.Checked = true;
                checkBox15.Checked = false;
                checkBox8.Checked = false;
                checkBox13.Checked = false;
            }

        }

        private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
        {
            if (comboBox1.SelectedText.Equals("10/08/2014-visit1"))
            {
                checkBox1.Checked = true;
                checkBox6.Checked = true;
                checkBox7.Checked = true;
                checkBox4.Checked = true;
                checkBox12.Checked = true;
                checkBox11.Checked = true;
                checkBox14.Checked = true;
                checkBox15.Checked = true;
                checkBox8.Checked = true;
            }
            else if (comboBox1.SelectedText.Equals("11/08/2014-visit2"))
            {
                checkBox1.Checked = false;
                checkBox6.Checked = true;
                checkBox7.Checked = false;
                checkBox4.Checked = true;
                checkBox12.Checked = true;
                checkBox11.Checked = false;
                checkBox14.Checked = true;
                checkBox15.Checked = false;
                checkBox8.Checked = true;
                checkBox13.Checked = true;
            }
            else
            {
                checkBox1.Checked = true;
                checkBox6.Checked = true;
                checkBox7.Checked = false;
                checkBox4.Checked = true;
                checkBox12.Checked = false;
                checkBox11.Checked = false;
                checkBox14.Checked = true;
                checkBox15.Checked = false;
                checkBox8.Checked = false;
                checkBox13.Checked = false;
            }
        }

        
        
    }
}
